/*
** synt_add.c for asm in /home/vanet_c//proj-kw/asm/folder_syntax/synt_
** 
** Made by charles-edouard vanet
** Login   <vanet_c@epitech.net>
** 
** Started on  Thu Dec 13 18:27:52 2012 charles-edouard vanet
** Last update Fri Dec 14 17:34:30 2012 charles-edouard vanet
*/

#include	"../../../includes/asm.h"

int	synt_add(char **tab, t_list **list, t_my_file **my_file, char **name)
{
  int	reg;
  int	i;

  i = 0;
  reg = 0;
  while (tab[++i])
    {
      if (char_cmp(tab[i][0], REG) == 0)
	reg++;
      else
	{
	  my_free_tab(name);
	  register_msg(list, my_file, tab[i]);
	}
    }
  if (reg == 3)
    return (0);
  return (1);
}
